package com.example.demo.service;

import com.example.demo.dtox.User;
import org.springframework.stereotype.Service;

@Service
public class UserService {
    public User getUser(String username) {
        return "sun".equals(username)
                ?User.builder()
                .name("sun")
                .password("123456")
                .build():null;
    }
}
